//author: create by SunJH
//时间: 2021/11/30 0030
//邮箱: 965989158@qq.com
//描述: 数据持久化的控制器
import 'package:flutter_app/utils/local_storage.dart';
import 'package:get/get.dart';

class CounterStorage extends GetxController{
  static final SKey = "SKY";
  static final IKey = "IKY";
  static final BKey = "BKY";
  var storageSData = "".obs;
  var storageIData = 0.obs;
  var storageBData = false.obs;
  var inputData = "".obs;

  @override
  void onInit() {
    storageSData.value = LocalStorage.getInstance().get(SKey);
    storageIData.value = LocalStorage.getInstance().get(IKey)??-1;
    storageBData.value = LocalStorage.getInstance().get(BKey)??false;
  }
}